define(function(){
    return function(goodsMsg){
        return goodsMsg.reduce((start,val)=>val.flag ?start+= val.num*val.price:start,0)
    }
})